<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<html>
<head>
	<title>商品入库记录列表</title>
	<meta name="decorator" content="default"/>
	<style type="text/css">
		.table td {
			vertical-align: middle;
		}
	</style>
	<script type="text/javascript">
		$(document).ready(function() {
			
		});
		function page(n,s){
			$("#pageNo").val(n);
			$("#pageSize").val(s);
			$("#searchForm").submit();
        	return false;
        }
	</script>
</head>
<body>
<form:form id="searchForm" modelAttribute="productInventoryDetail" action="${ctx}/ivm/inventory/showInventoryDetail" method="post">
	<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
	<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
	<form:hidden path="product.id"/>
	<div style="margin:10px;">
		<table id="contentTable" class="table table-striped table-bordered table-condensed">
			<thead>
				<tr>
					<th>入库时间</th>
					<th>入库量</th>
					<th>采购金额</th>
					<th>采购指令编号</th>
				</tr>
			</thead>
			<tbody>
			<c:forEach items="${page.list}" var="detail">
				<tr>
					<td><fmt:formatDate value="${detail.createDate }" pattern="yyyy-MM-dd HH:mm:ss"/></td>
					<td>${detail.winWeight }${detail.product.specUnit.name }</td>
					<td>${detail.amount }元</td>
					<td>${detail.purchase != null && detail.purchase.id != '' ? detail.purchase.code : '' }</td>
				</tr>
			</c:forEach>
			</tbody>
		</table>
		<div class="pagination">${page}</div>
	</div>
</form:form>
</body>
</html>